package com.iims.market.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.iims.market.domain.PurposeContract;
import com.iims.market.vo.GroupPurposeContractSearchQuery;

import java.util.List;

/**
 * 意向合同mapper
 *
 * @author fanpei
 * @date 2021/6/17 15:00
 */
public interface PurposeContractMapper extends BaseMapper<PurposeContract> {

    /**
     * 获取意向合同详情
     *
     * @param pContractId
     * @return
     */
    PurposeContract selectPContractDetailById(Long pContractId);

    /**
     * 获取扩展信息
     *
     * @param pContractId
     * @return
     */
    String selectPContractExtentions(Long pContractId);

    /**
     * 获取意向合同列表
     *
     * @param pContract
     * @return
     */
    List<PurposeContract> selectPContractList(PurposeContract pContract);

    /**
     * 分组获取意向合同列表
     *
     * @param groupSearchQuery
     * @return
     */
    List<PurposeContract> selectPContractListByGroup(GroupPurposeContractSearchQuery groupSearchQuery);

    /**
     * 获取意向合同正式合同编号
     *
     * @param pContractId
     * @return
     */
    String selectPContractOfficialCode(Long pContractId);
}
